function [g1, T_order, T] = static_g1(y, x, params, sparse_rowval, sparse_colval, sparse_colptr, T_order, T)
if nargin < 8
    T_order = -1;
    T = NaN(16, 1);
end
[T_order, T] = M30ra.sparse.static_g1_tt(y, x, params, T_order, T);
g1_v = NaN(29, 1);
g1_v(1)=T(4)*(params(4)-1)*params(8)*1/y(5)-T(5)*(params(4)-1)*1/y(5);
g1_v(2)=params(4)*params(8)*T(4)*params(1)*1/y(3)-T(5)*params(1)*params(4)*1/y(3);
g1_v(3)=params(8);
g1_v(4)=(-1);
g1_v(5)=1;
g1_v(6)=(-(1/y(5)));
g1_v(7)=T(1)*T(12)-(params(4)-1)*y(1)/y(5)*T(13);
g1_v(8)=T(13)+T(6)*params(4)*params(8)*params(1)*T(12)-(1-params(3)+params(4)*T(6))*params(1)*T(13);
g1_v(9)=1;
g1_v(10)=params(4)*params(8)*T(4)*params(1)*(-y(1))/(y(3)*y(3))-T(5)*params(1)*params(4)*(-y(1))/(y(3)*y(3));
g1_v(11)=(-(T(8)*exp(y(7))*T(14)));
g1_v(12)=(-(1-(1-params(3))));
g1_v(13)=(-(T(8)*params(4)*getPowerDeriv(y(3),params(4)-1,1)));
g1_v(14)=(-(T(10)*(1-params(4))*T(14)));
g1_v(15)=1;
g1_v(16)=1;
g1_v(17)=T(4)*(params(4)-1)*params(8)*(-y(1))/(y(5)*y(5))-(params(2)*getPowerDeriv(y(5),params(7),1)+T(5)*(params(4)-1)*(-y(1))/(y(5)*y(5)));
g1_v(18)=(-(T(7)*exp(y(7))*T(15)));
g1_v(19)=(-((-y(1))/(y(5)*y(5))));
g1_v(20)=(-(T(9)*T(15)));
g1_v(21)=(-(T(7)*(1-params(4))*getPowerDeriv(y(5),(-params(4)),1)));
g1_v(22)=1;
g1_v(23)=(-(T(7)*exp(y(7))*T(8)));
g1_v(24)=1-params(5);
g1_v(25)=1;
g1_v(26)=1;
g1_v(27)=T(1)*T(16)-(params(4)-1)*y(1)/y(5)*T(5)*(-log(y(2)));
g1_v(28)=T(5)*(-log(y(2)))+T(6)*params(4)*params(8)*params(1)*T(16)-(1-params(3)+params(4)*T(6))*params(1)*T(5)*(-log(y(2)));
g1_v(29)=1;
if ~isoctave && matlab_ver_less_than('9.8')
    sparse_rowval = double(sparse_rowval);
    sparse_colval = double(sparse_colval);
end
g1 = sparse(sparse_rowval, sparse_colval, g1_v, 10, 10);
end
